package com.hellobike.haxing.modules.product.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.hellobike.haxing.modules.product.entity.Tag;
import com.hellobike.haxing.modules.product.mapper.TagMapper;
import com.hellobike.haxing.modules.product.service.ITagService;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.List;

/**
 * @Description: 标签
 * @Author: haxing-boot
 * @Date:   2020-01-17
 * @Version: V1.0
 */
@Service
public class TagServiceImpl extends ServiceImpl<TagMapper, Tag> implements ITagService {

    @Override
    public List<Tag> getTagsByType(Integer type) {
        return baseMapper.selectList(new QueryWrapper<Tag>().lambda().eq(Tag::getType, type));
    }
}
